# coding: utf-8
t = ('hello', 'world', 18, 'apple', None)
print(t)

# 使用函数 tuple() 将列表转换为元组
array = ['hello', 'world', 18, 'apple', None]
t = tuple(array)
print(t)
print(tuple('hello'))

# 元组的相关操作
t = (1, 2, 3, 4, 5, 6, 3, 8, 9)
print('18在元组中是否存在:', 18 in t)
print('max:', max(t))
print('min:', min(t))
print('count:', t.count(3))
print(type(t))

x = (11)
# int
print(type(x))

x = (10,)
# tuple
print(type(x))
